package com.example.streamproducer.stream;

import org.springframework.cloud.stream.annotation.Output;
import org.springframework.messaging.MessageChannel;
import org.springframework.stereotype.Component;

/**
 * @Author: lihui
 * @Date: 2022-03-23 08:58
 * @Description:
 */
@Component
public interface OutputInterface {

    String MSG_OUTPUT ="msg-output";

    String DEFAULT = "default.message"; // 约定大于配置，默认名称就是交换机名称

    @Output(MSG_OUTPUT)
    MessageChannel sendMsg();

    @Output(DEFAULT)
    MessageChannel sendDefaultMsg();

}
